The previous section introduced the concept of literals, data values embedded directly within your VectorScript code. Scripts that operate only on such static data are rather limited and inflexible; to move beyond this limitation, VectorScript uses
constants and
variables. Constants and variables are names (more technically,
identifiers) that which have associated data values; we say that the variable or constant “stores” or “contains” the value.
Constants and variables provide a way to store and manipulate values by name. In the case of constants, the value cannot be changed during script execution; in the case of variables, however, the value associated with a name may be changed at any point by assigning a new value to the name (hence the term “variable”).
Another important VectorScript concept is that of data types. As the name implies, data types are the kinds of data that can be manipulated by your scripts. Data types provide structure and meaning to the information being manipulated by a script, allowing VectorScript to process it efficiently and safely.